package com.freemarker.vo;

import com.freemarker.db.StringUtil;

public class ColumnEntity {

	private String columnName;
	private String columnDataType;
	private String columnComment;

	private boolean pki;

	private long columnMaxLength;
	private boolean requiredField;
	private String defaultValue;
	private String columnExtra;

	/** 首字母大写。如 UserName */
	private String javaName;
	/** 首字母小写。如 userName */
	private String javaname;

	/** 首字母大写。如 UserName 强制包装类型的属性名 */
	private String javaDataType;

	/** 强制包装类型 */
	private String javaDataTypeWrapper;

	private HtmlEntity htmlEntity;

	public ColumnEntity() {

	}

	public String getColumnName() {
		return StringUtil.trim(columnName);
	}

	public void setColumnName(String columnName) {
		this.columnName = StringUtil.trim(columnName);
	}

	public String getColumnDataType() {
		return StringUtil.trim(columnDataType);
	}

	public void setColumnDataType(String columnDataType) {
		this.columnDataType = StringUtil.trim(columnDataType);
	}

	public String getColumnComment() {
		return StringUtil.trim(columnComment);
	}

	public void setColumnComment(String columnComment) {
		this.columnComment = StringUtil.trim(columnComment);
	}

	public boolean isPki() {
		return pki;
	}

	public void setPki(boolean pki) {
		this.pki = pki;
	}

	public long getColumnMaxLength() {
		return columnMaxLength;
	}

	public void setColumnMaxLength(long columnMaxLength) {
		this.columnMaxLength = columnMaxLength;
	}

	public boolean isRequiredField() {
		return requiredField;
	}

	public void setRequiredField(boolean requiredField) {
		this.requiredField = requiredField;
	}

	public String getDefaultValue() {
		return StringUtil.trim(defaultValue);
	}

	public void setDefaultValue(String defaultValue) {
		this.defaultValue = StringUtil.trim(defaultValue);
	}

	public String getColumnExtra() {
		return StringUtil.trim(columnExtra);
	}

	public void setColumnExtra(String columnExtra) {
		this.columnExtra = StringUtil.trim(columnExtra);
	}

	/** 首字母大写。如 UserName */
	public String getJavaName() {
		return StringUtil.trim(javaName);
	}

	/** 首字母大写。如 UserName */
	public void setJavaName(String javaName) {
		this.javaName = StringUtil.trim(javaName);
	}

	public String getJavaDataType() {
		return StringUtil.trim(javaDataType);
	}

	public void setJavaDataType(String javaDataType) {
		this.javaDataType = StringUtil.trim(javaDataType);
	}

	/** 首字母小写。如 userName */
	public String getJavaname() {
		return StringUtil.trim(javaname);
	}

	/** 首字母小写。如 userName */
	public void setJavaname(String javaname) {
		this.javaname = StringUtil.trim(javaname);
	}

	public String getJavaDataTypeWrapper() {
		return StringUtil.trim(javaDataTypeWrapper);
	}

	public void setJavaDataTypeWrapper(String javaDataTypeWrapper) {
		this.javaDataTypeWrapper = StringUtil.trim(javaDataTypeWrapper);
	}

	public HtmlEntity getHtmlEntity() {
		return htmlEntity;
	}

	public void setHtmlEntity(HtmlEntity htmlEntity) {
		this.htmlEntity = htmlEntity;
	}

	@Override
	public String toString() {
		return "ColumnEntity [columnName=" + columnName + ", columnDataType=" + columnDataType + ", columnComment=" + columnComment + ", pki=" + pki
				+ ", columnMaxLength=" + columnMaxLength + ", requiredField=" + requiredField + ", defaultValue=" + defaultValue + ", columnExtra="
				+ columnExtra + ", javaName=" + javaName + ", javaname=" + javaname + ", javaDataType=" + javaDataType + ", javaDataTypeWrapper="
				+ javaDataTypeWrapper + ", htmlEntity=" + htmlEntity + "]";
	}

}
